<?php
namespace app\index\controller;

use think\Controller;
use app\index\service\ProjectService;
class Project extends Controller
{
    private $projectService;

    /**
     * 依赖注入 Service
     *
     * @param ProjectService $projectService
     * @author zws
     */
    public function __construct(ProjectService $projectService)
    {
        $this->projectService = $projectService;
        parent::__construct();
    }

    /**
     * 查询项目
     * @return \think\response\Json
     * @author zws
     */
    public function index()
    {
        $input = $this->request->input;
        $result = $this->projectService->index($input);
        return app_response(200, $result);
    }
}